﻿@model Dictionary<string, Dictionary<string, object>>
@{
    ViewBag.Title = "试图数据列表";

    ViewBag.jQuery = true;
    ViewBag.jQueryUI = true;
    ViewBag.Json = true;
    ViewBag.Flexigrid = true;
    ViewBag.Global = true;

    ViewBag.Css = "/Content/ViewSetting/Site.css";
    ViewBag.Js = "/Content/" + ViewContext.RouteData.Values["ViewForder"] + "/" + ViewContext.RouteData.Values["ViewName"] + ".js";

    Layout = "~/Views/_Template.cshtml";
}
<table id="MainTable" cellpadding="0" cellspacing="4" width="100%">
    <tr id="TitleTR"><td class="PageTitle"><div class="Title">在线用户管理</div><input type="hidden" name="UrlAction" value="@Html.Raw(ViewBag.UrlAction)" /></td></tr>   
    <tr><td>
        <table id="SettingList" class="flexme3">
            <tbody> 
@{ 
    string DateTimeStr;
    foreach (string m in Model.Keys)
    {
        if (Model[m].ContainsKey("AsynchronousUserID"))
        {
            DateTimeStr = ((DateTime)Model[m]["AsynchronousLoginTime"]).ToString("yy-MM-dd HH:mm:ss.fff");
                <tr>
	                <td>@m</td>  
	                <td>@Model[m]["AsynchronousUserID"]</td>             
	                <td>@DateTimeStr</td>   
	                <td>@Model[m]["Username"]</td>      
	                <td>@((bool)Model[m]["Lock"] ? "临时锁定状态" : "")</td>      
	                <td><a href="javascript:Lock('@m')" style="display:@((bool)Model[m]["Lock"] ? "none" : "inline")" class="Operation">临时锁定</a><a href="javascript:UnLock('@m')" style="display:@(!(bool)Model[m]["Lock"] ? "none" : "inline")">解除锁定</a></td>  
                </tr>
        }
        else
        {
                <tr>
	                <td>@m</td>  
	                <td>Guest</td>             
	                <td></td>          
	                <td></td>            
	                <td></td>        
	                <td></td>  
                </tr>
        }
    }
}
            </tbody>
        </table>
    </td></tr>
</table>